gridpack::math::NonlinearSolverT< T, I > Class Template Reference

A solver for a system of nonlinear system of equations in parallel. More...

#include <nonlinear_solver.hpp>

Inheritance diagram for gridpack::math::NonlinearSolverT< T, I >:
Inheritance graph
[legend]
Collaboration diagram for gridpack::math::NonlinearSolverT< T, I >:
Collaboration graph
[legend]

List of all members.

Public Types

typedef
NonlinearSolverImplementation
< T, I >::VectorType 
VectorType
typedef
NonlinearSolverImplementation
< T, I >::MatrixType 
MatrixType
typedef
NonlinearSolverImplementation
< T, I >::JacobianBuilder 
JacobianBuilder
typedef
NonlinearSolverImplementation
< T, I >::FunctionBuilder 
FunctionBuilder

Public Member Functions

 NonlinearSolverT (const parallel::Communicator &comm, const int &local_size, JacobianBuilder form_jacobian, FunctionBuilder form_function)
 Default constructor.
 NonlinearSolverT (MatrixType &J, JacobianBuilder form_jacobian, FunctionBuilder form_function)
 ~NonlinearSolverT (void)
 Destructor.

Detailed Description

template<typename T, typename I = int>
class gridpack::math::NonlinearSolverT< T, I >

A solver for a system of nonlinear system of equations in parallel.

This class is used to solve a system of nonlinear equations in the form

\[ \left[ \mathbf{J}\left( \mathbf{x} \right) \right] \Delta \mathbf{x} ~ = ~ -\mathbf{F}\left( \mathbf{x} \right) \]

where $\mathbf{J}\left( \mathbf{x} \right)$ is the Jacobian matrix, $\mathbf{x}$ is the solution Vector, and $\mathbf{F}\left( \mathbf{x} \right)$ is some Vector function of $\mathbf{x}$.

Users of this class must specify functions or functors that build the Jacobian Matrix and the right hand side Vector. Typically, it's best to use functor classes or structs, since extra required information can be available to the Matrix/Vector construction.

Implementation ...


Member Typedef Documentation

template<typename T , typename I = int>
typedef NonlinearSolverImplementation<T, I>::FunctionBuilder gridpack::math::NonlinearSolverT< T, I >::FunctionBuilder
template<typename T , typename I = int>
typedef NonlinearSolverImplementation<T, I>::JacobianBuilder gridpack::math::NonlinearSolverT< T, I >::JacobianBuilder
template<typename T , typename I = int>
typedef NonlinearSolverImplementation<T, I>::MatrixType gridpack::math::NonlinearSolverT< T, I >::MatrixType
template<typename T , typename I = int>
typedef NonlinearSolverImplementation<T, I>::VectorType gridpack::math::NonlinearSolverT< T, I >::VectorType

Constructor & Destructor Documentation

template<typename T , typename I = int>
gridpack::math::NonlinearSolverT< T, I >::NonlinearSolverT ( const parallel::Communicator comm,
const int &  local_size,
JacobianBuilder  form_jacobian,
FunctionBuilder  form_function 
)

Default constructor.

Collective.

A NonlinearSolverT must be constructed simultaneously on all processes involved in comm.

Parameters:
comm communicator on which the instance is to exist
local_size number Jacobian rows and Vector entries to be owned by this process
form_jacobian function to fill the Jacobian Matrix, $\left[ \mathbf{J}\left( \mathbf{x} \right) \right]$
form_function function to fill the RHS function Vector, $\mathbf{F}\left( \mathbf{x} \right)$
Returns:
new NonlinearSolverT instance
template<typename T , typename I = int>
gridpack::math::NonlinearSolverT< T, I >::NonlinearSolverT ( MatrixType J,
JacobianBuilder  form_jacobian,
FunctionBuilder  form_function 
)
template<typename T , typename I = int>
gridpack::math::NonlinearSolverT< T, I >::~NonlinearSolverT ( void   ) 

Destructor.

This must be called simultaneously by all processes involved in the communicator used for construction.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated on 3 Feb 2020 for GridPACK by  doxygen 1.6.1